<template>
    <a-card>
        <div class="account-settings-info-main">
            <!-- 设置菜单 -->
            <div class="account-settings-info-left">
                <a-menu
                    :mode="'inline'"
                    :selectedKeys="[$route.name]"
                    :style="{ border: '0'}" >
                    <!-- 遍历菜单 -->
                    <a-menu-item v-for="menu in menuList" :key="menu.routerLink.name">
                        <router-link :to="menu.routerLink">{{ menu.title }}</router-link>
                    </a-menu-item>
                </a-menu>
            </div>
            <!-- 主体 -->
            <div class="account-settings-info-right">
                <div class="account-settings-info-title">
                    <span>{{ $route.meta.title }}</span>
                </div>
                <router-view />
            </div>
        </div>
    </a-card>
</template>

<script>
    export default {
        data() {
            return {
                //  菜单列表
                menuList : [
                    { routerLink : { name: 'myBaseInfoSettings' }, title : '基本信息' },
                    // { routerLink : { name: 'securitySettings' }, title : '安全设置' },
                    // { routerLink : { name: 'accountBinding' }, title : '账号绑定' }
                ]
            };
        }
    }
</script>
<style lang="less" scoped>
    .account-settings-info-main {
        width: 100%;
        display: flex;
        height: 100%;
        overflow: auto;

        .account-settings-info-left {
            border-right: 1px solid #e8e8e8;
            width: 224px;
        }

        .account-settings-info-right {
            flex: 1 1;
            padding: 8px 40px;

            .account-settings-info-title {
                color: rgba(0,0,0,.85);
                font-size: 20px;
                font-weight: 500;
                line-height: 28px;
                margin-bottom: 12px;
            }
            .account-settings-info-view {
                padding-top: 12px;
            }
        }
    }
</style>
